package com.springboot.service.task;

import lombok.extern.slf4j.Slf4j;
import org.springframework.scheduling.annotation.Scheduled;
import org.springframework.stereotype.Component;

/**
 * @Author: luobendexiaoqiang
 * @Date: 2020/7/24 19:39
 */
@Component
@Slf4j
public class TaskTest {
    /**
     * 五秒执行一次
     */
    @Scheduled(fixedRate = 5 * 1000)
    public void taskTest() {
        log.info("五秒一次定时任务开始执行!!");
    }

}
